-- single values
DECLARE 
	@data VARCHAR(9),
	@encryptedData VARCHAR(50)
SELECT 
	@data = '12345',
	@encryptedData = dbo.fn_Encrypt(@data)
SELECT 
	@data AS [original data],
	dbo.fn_Decrypt(@encryptedData) AS [decrypted data],
	@encryptedData AS [encrypted data]

-- lists
DECLARE 
	@data2 VARCHAR(9),
	@tblIn dbo.CryptoUpdater,
	@tblOut dbo.CryptoUpdater
SELECT @data2 = '45678'
INSERT @tblIn VALUES (@data, null)
INSERT @tblIn VALUES (@data2, null)
SELECT * FROM @tblIn

-- encrypted data
INSERT @tblOut SELECT * FROM dbo.fn_EncryptList(@tblIn)
SELECT * FROM @tblOut

-- decrypted data
DELETE @tblIn
INSERT @tblIn SELECT * FROM dbo.fn_DecryptList(@tblOut)
SELECT * FROM @tblIn
